package io.rong.imkit;

import android.content.Context;

public class IMManager {

    private static IMManager imManager;
    private final Context context;

    private IMManager(Context context) {
        this.context = context;
    }

    public static void init(Context context) {
        if (imManager == null) {
            synchronized (IMManager.class) {
                if (imManager == null) {
                    imManager = new IMManager(context);
                }
            }
        }
    }

    public static IMManager getInstance() {
        return imManager;
    }

    public Context getContext() {
        return context;
    }
}
